3.27 \(\int \frac {A+B x}{x^2 \sqrt {a+b x^2}} \, dx\)

Optimal. Leaf size=47 \[ -\frac {A \sqrt {a+b x^2}}{a x}-\frac {B \tanh ^{-1}\left (\frac {\sqrt {a+b x^2}}{\sqrt {a}}\right )}{\sqrt {a}} \]

[Out]

-B*arctanh((b*x^2+a)^(1/2)/a^(1/2))/a^(1/2)-A*(b*x^2+a)^(1/2)/a/x

________________________________________________________________________________________

Rubi [A]  time = 0.03, antiderivative size = 47, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 4, integrand size = 20, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.200, Rules used = {807, 266, 63, 208} \[ -\frac {A \sqrt {a+b x^2}}{a x}-\frac {B \tanh ^{-1}\left (\frac {\sqrt {a+b x^2}}{\sqrt {a}}\right )}{\sqrt {a}} \]

Antiderivative was successfully verified.

[In]

Int[(A + B*x)/(x^2*Sqrt[a + b*x^2]),x]

[Out]

-((A*Sqrt[a + b*x^2])/(a*x)) - (B*ArcTanh[Sqrt[a + b*x^2]/Sqrt[a]])/Sqrt[a]

Rule 63

Int[((a_.) + (b_.)*(x_))^(m_)*((c_.) + (d_.)*(x_))^(n_), x_Symbol] :> With[{p = Denominator[m]}, Dist[p/b, Sub
st[Int[x^(p*(m + 1) - 1)*(c - (a*d)/b + (d*x^p)/b)^n, x], x, (a + b*x)^(1/p)], x]] /; FreeQ[{a, b, c, d}, x] &
& NeQ[b*c - a*d, 0] && LtQ[-1, m, 0] && LeQ[-1, n, 0] && LeQ[Denominator[n], Denominator[m]] && IntLinearQ[a,
b, c, d, m, n, x]

Rule 208

Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(Rt[-(a/b), 2]*ArcTanh[x/Rt[-(a/b), 2]])/a, x] /; FreeQ[{a,
b}, x] && NegQ[a/b]

Rule 266

Int[(x_)^(m_.)*((a_) + (b_.)*(x_)^(n_))^(p_), x_Symbol] :> Dist[1/n, Subst[Int[x^(Simplify[(m + 1)/n] - 1)*(a
+ b*x)^p, x], x, x^n], x] /; FreeQ[{a, b, m, n, p}, x] && IntegerQ[Simplify[(m + 1)/n]]

Rule 807

Int[((d_.) + (e_.)*(x_))^(m_)*((f_.) + (g_.)*(x_))*((a_) + (c_.)*(x_)^2)^(p_.), x_Symbol] :> -Simp[((e*f - d*g
)*(d + e*x)^(m + 1)*(a + c*x^2)^(p + 1))/(2*(p + 1)*(c*d^2 + a*e^2)), x] + Dist[(c*d*f + a*e*g)/(c*d^2 + a*e^2
), Int[(d + e*x)^(m + 1)*(a + c*x^2)^p, x], x] /; FreeQ[{a, c, d, e, f, g, m, p}, x] && NeQ[c*d^2 + a*e^2, 0]
&& EqQ[Simplify[m + 2*p + 3], 0]

Rubi steps

\begin {align*} \int \frac {A+B x}{x^2 \sqrt {a+b x^2}} \, dx &=-\frac {A \sqrt {a+b x^2}}{a x}+B \int \frac {1}{x \sqrt {a+b x^2}} \, dx\\ &=-\frac {A \sqrt {a+b x^2}}{a x}+\frac {1}{2} B \operatorname {Subst}\left (\int \frac {1}{x \sqrt {a+b x}} \, dx,x,x^2\right )\\ &=-\frac {A \sqrt {a+b x^2}}{a x}+\frac {B \operatorname {Subst}\left (\int \frac {1}{-\frac {a}{b}+\frac {x^2}{b}} \, dx,x,\sqrt {a+b x^2}\right )}{b}\\ &=-\frac {A \sqrt {a+b x^2}}{a x}-\frac {B \tanh ^{-1}\left (\frac {\sqrt {a+b x^2}}{\sqrt {a}}\right )}{\sqrt {a}}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]  time = 0.04, size = 47, normalized size = 1.00 \[ -\frac {A \sqrt {a+b x^2}}{a x}-\frac {B \tanh ^{-1}\left (\frac {\sqrt {a+b x^2}}{\sqrt {a}}\right )}{\sqrt {a}} \]

Antiderivative was successfully verified.

[In]

Integrate[(A + B*x)/(x^2*Sqrt[a + b*x^2]),x]

[Out]

-((A*Sqrt[a + b*x^2])/(a*x)) - (B*ArcTanh[Sqrt[a + b*x^2]/Sqrt[a]])/Sqrt[a]

________________________________________________________________________________________

fricas [A]  time = 0.95, size = 101, normalized size = 2.15 \[ \left [\frac {B \sqrt {a} x \log \left (-\frac {b x^{2} - 2 \, \sqrt {b x^{2} + a} \sqrt {a} + 2 \, a}{x^{2}}\right ) - 2 \, \sqrt {b x^{2} + a} A}{2 \, a x}, \frac {B \sqrt {-a} x \arctan \left (\frac {\sqrt {-a}}{\sqrt {b x^{2} + a}}\right ) - \sqrt {b x^{2} + a} A}{a x}\right ] \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((B*x+A)/x^2/(b*x^2+a)^(1/2),x, algorithm="fricas")

[Out]

[1/2*(B*sqrt(a)*x*log(-(b*x^2 - 2*sqrt(b*x^2 + a)*sqrt(a) + 2*a)/x^2) - 2*sqrt(b*x^2 + a)*A)/(a*x), (B*sqrt(-a
)*x*arctan(sqrt(-a)/sqrt(b*x^2 + a)) - sqrt(b*x^2 + a)*A)/(a*x)]

________________________________________________________________________________________

giac [A]  time = 0.51, size = 65, normalized size = 1.38 \[ \frac {2 \, B \arctan \left (-\frac {\sqrt {b} x - \sqrt {b x^{2} + a}}{\sqrt {-a}}\right )}{\sqrt {-a}} + \frac {2 \, A \sqrt {b}}{{\left (\sqrt {b} x - \sqrt {b x^{2} + a}\right )}^{2} - a} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((B*x+A)/x^2/(b*x^2+a)^(1/2),x, algorithm="giac")

[Out]

2*B*arctan(-(sqrt(b)*x - sqrt(b*x^2 + a))/sqrt(-a))/sqrt(-a) + 2*A*sqrt(b)/((sqrt(b)*x - sqrt(b*x^2 + a))^2 -
a)

________________________________________________________________________________________

maple [A]  time = 0.01, size = 49, normalized size = 1.04 \[ -\frac {B \ln \left (\frac {2 a +2 \sqrt {b \,x^{2}+a}\, \sqrt {a}}{x}\right )}{\sqrt {a}}-\frac {\sqrt {b \,x^{2}+a}\, A}{a x} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((B*x+A)/x^2/(b*x^2+a)^(1/2),x)

[Out]

-A*(b*x^2+a)^(1/2)/a/x-B/a^(1/2)*ln((2*a+2*(b*x^2+a)^(1/2)*a^(1/2))/x)

________________________________________________________________________________________

maxima [A]  time = 1.31, size = 37, normalized size = 0.79 \[ -\frac {B \operatorname {arsinh}\left (\frac {a}{\sqrt {a b} {\left | x \right |}}\right )}{\sqrt {a}} - \frac {\sqrt {b x^{2} + a} A}{a x} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((B*x+A)/x^2/(b*x^2+a)^(1/2),x, algorithm="maxima")

[Out]

-B*arcsinh(a/(sqrt(a*b)*abs(x)))/sqrt(a) - sqrt(b*x^2 + a)*A/(a*x)

________________________________________________________________________________________

mupad [B]  time = 1.20, size = 39, normalized size = 0.83 \[ -\frac {B\,\mathrm {atanh}\left (\frac {\sqrt {b\,x^2+a}}{\sqrt {a}}\right )}{\sqrt {a}}-\frac {A\,\sqrt {b\,x^2+a}}{a\,x} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((A + B*x)/(x^2*(a + b*x^2)^(1/2)),x)

[Out]

- (B*atanh((a + b*x^2)^(1/2)/a^(1/2)))/a^(1/2) - (A*(a + b*x^2)^(1/2))/(a*x)

________________________________________________________________________________________

sympy [A]  time = 2.80, size = 41, normalized size = 0.87 \[ - \frac {A \sqrt {b} \sqrt {\frac {a}{b x^{2}} + 1}}{a} - \frac {B \operatorname {asinh}{\left (\frac {\sqrt {a}}{\sqrt {b} x} \right )}}{\sqrt {a}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((B*x+A)/x**2/(b*x**2+a)**(1/2),x)

[Out]

-A*sqrt(b)*sqrt(a/(b*x**2) + 1)/a - B*asinh(sqrt(a)/(sqrt(b)*x))/sqrt(a)

________________________________________________________________________________________